package DDL;

import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import java.util.Map;

import DML.InsertTable;
import DML.Table;
import DuiXiang.TableModel;
import Main.ParsingSql;

public class test {
	public static void main(String args[]) {

		ParsingSql parsingSql = new ParsingSql();
		List<List<String>> resultSet = new ArrayList<List<String>>();
		List<String>  attrList=new ArrayList<String>();
		 GetTableMessage.getTableMessage("student", "info", attrList);
		 for (int i = 0; i < attrList.size(); i++) {
				System.out.println(attrList.get(i));
			}
//		 System.out.println(parsingSql.parsingSql(
//		 "  CREATE   database work;",resultSet));//创建数据库
		/* System.out.println(parsingSql.parsingSql(
		 "  drop   database teacher;",resultSet));//删除数据库*/
//		 System.out.println(parsingSql.parsingSql(
//		 "  CREATE   TABLE Table"
//		 + "(Name  varchar[10] KEY  NO_NULL ,"
//		 + "" + "	"
//		 + "	Age int NOT_KEY NO_NULL VALID)INTO work;",
//		 resultSet));//创建表
//		 System.out
//		 .println(parsingSql
//		 .parsingSql(
//		 "  EDIT TABLE TableHwq(Name  char[10] KEY  NO_NULL , Age "
//		 + ""
//		 + "float NOT_KEY NO_NULL VALID)IN work;",
//		 resultSet));//编辑表
//		 System.out.println(parsingSql.parsingSql(" insert into " + ""
//		 + "Table values ('胡伟强',123) in work;", resultSet));//插入数据
//		 System.out.println(parsingSql.parsingSql(" update " + ""
//		 + "Table (SET Age=234 where Name='hwqer') in work;",
//		 resultSet));//update表
//		System.out.println(parsingSql.parsingSql(" select * " + "  "
//				+ "from Table in work;", resultSet));// select语句
//		 System.out.println(parsingSql.parsingSql(" delete " + "  "
//		 + "from TableHwq where Name='hwqer' in work;", resultSet));//删除数据
//		for (int i = 0; i < resultSet.size(); i++) {
//			System.out.println(resultSet.get(i));
//		}
	}
}
